package com.namecard.namecardapi.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

@Data
@ApiModel(description = "商品")
@TableName("t_commodity")
public class TCommodity extends BaseEntity {

	private static final long serialVersionUID = 1L;

	@ApiModelProperty(value = "商品名")
	@TableField("trade_name")
	private String tradeName;

	@ApiModelProperty(value = "商品描述")
	@TableField("description")
	private String description;

	@ApiModelProperty(value = "价格")
	@TableField("price")
	private Double price;

	@ApiModelProperty(value = "成交量")
	@TableField("turnover")
	private Long turnover;

	@ApiModelProperty(value = "浏览量")
	@TableField("page_view")
	private Long pageView;


	@ApiModelProperty(value = "图片集合")
	@TableField("img_list")
	private String imgList;

	@ApiModelProperty(value = "商品分类id")
	@TableField("cate_id")
	private Long cateId;

	@ApiModelProperty(value = "添加时间")
	@TableField("create_time")
	private Date createTime;

	@ApiModelProperty(value = "修改时间")
	@TableField("update_time")
	private Date updateTime;

	@ApiModelProperty(value = "状态（1：软删除 0：未删除）")
	@TableField("is_deleted")
	private Integer isDeleted;

	@ApiModelProperty(value = "商品状态（1：下架 0：上架）")
	@TableField("state")
	private Integer state;

	@TableField(exist = false)
	private String cateName;

	@ApiModelProperty(value = "滚动（1：滚 0：不滚）")
	@TableField("roll")
	private Integer roll;
}

